Integrand size = 18, antiderivative size = 65 \[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=\frac {a \cos \left (e-\frac {c f}{d}\right ) \operatorname {CosIntegral}\left (\frac {c f}{d}+f x\right )}{d}+\frac {a \log (c+d x)}{d}-\frac {a \sin \left (e-\frac {c f}{d}\right ) \text {Si}\left (\frac {c f}{d}+f x\right )}{d} \]
[Out]
Time = 0.17 (sec) , antiderivative size = 65, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {3398, 3384, 3380, 3383} \[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=\frac {a \operatorname {CosIntegral}\left (x f+\frac {c f}{d}\right ) \cos \left (e-\frac {c f}{d}\right )}{d}-\frac {a \sin \left (e-\frac {c f}{d}\right ) \text {Si}\left (x f+\frac {c f}{d}\right )}{d}+\frac {a \log (c+d x)}{d} \]
[In]
[Out]
Rule 3380
Rule 3383
Rule 3384
Rule 3398
Rubi steps \begin{align*} \text {integral}& = \int \left (\frac {a}{c+d x}+\frac {a \cos (e+f x)}{c+d x}\right ) \, dx \\ & = \frac {a \log (c+d x)}{d}+a \int \frac {\cos (e+f x)}{c+d x} \, dx \\ & = \frac {a \log (c+d x)}{d}+\left (a \cos \left (e-\frac {c f}{d}\right )\right ) \int \frac {\cos \left (\frac {c f}{d}+f x\right )}{c+d x} \, dx-\left (a \sin \left (e-\frac {c f}{d}\right )\right ) \int \frac {\sin \left (\frac {c f}{d}+f x\right )}{c+d x} \, dx \\ & = \frac {a \cos \left (e-\frac {c f}{d}\right ) \operatorname {CosIntegral}\left (\frac {c f}{d}+f x\right )}{d}+\frac {a \log (c+d x)}{d}-\frac {a \sin \left (e-\frac {c f}{d}\right ) \text {Si}\left (\frac {c f}{d}+f x\right )}{d} \\ \end{align*}
Time = 0.22 (sec) , antiderivative size = 55, normalized size of antiderivative = 0.85 \[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=\frac {a \left (\cos \left (e-\frac {c f}{d}\right ) \operatorname {CosIntegral}\left (f \left (\frac {c}{d}+x\right )\right )+\log (c+d x)-\sin \left (e-\frac {c f}{d}\right ) \text {Si}\left (f \left (\frac {c}{d}+x\right )\right )\right )}{d} \]
[In]
[Out]
Time = 0.93 (sec) , antiderivative size = 86, normalized size of antiderivative = 1.32
method | result | size |
parts | \(\frac {a \ln \left (d x +c \right )}{d}+a \left (\frac {\operatorname {Si}\left (f x +e +\frac {c f -d e}{d}\right ) \sin \left (\frac {c f -d e}{d}\right )}{d}+\frac {\operatorname {Ci}\left (f x +e +\frac {c f -d e}{d}\right ) \cos \left (\frac {c f -d e}{d}\right )}{d}\right )\) | \(86\) |
derivativedivides | \(\frac {a f \left (\frac {\operatorname {Si}\left (f x +e +\frac {c f -d e}{d}\right ) \sin \left (\frac {c f -d e}{d}\right )}{d}+\frac {\operatorname {Ci}\left (f x +e +\frac {c f -d e}{d}\right ) \cos \left (\frac {c f -d e}{d}\right )}{d}\right )+\frac {a f \ln \left (c f -d e +d \left (f x +e \right )\right )}{d}}{f}\) | \(102\) |
default | \(\frac {a f \left (\frac {\operatorname {Si}\left (f x +e +\frac {c f -d e}{d}\right ) \sin \left (\frac {c f -d e}{d}\right )}{d}+\frac {\operatorname {Ci}\left (f x +e +\frac {c f -d e}{d}\right ) \cos \left (\frac {c f -d e}{d}\right )}{d}\right )+\frac {a f \ln \left (c f -d e +d \left (f x +e \right )\right )}{d}}{f}\) | \(102\) |
risch | \(\frac {a \ln \left (d x +c \right )}{d}-\frac {a \,{\mathrm e}^{\frac {i \left (c f -d e \right )}{d}} \operatorname {Ei}_{1}\left (i f x +i e +\frac {i \left (c f -d e \right )}{d}\right )}{2 d}-\frac {a \,{\mathrm e}^{-\frac {i \left (c f -d e \right )}{d}} \operatorname {Ei}_{1}\left (-i f x -i e -\frac {i c f -i d e}{d}\right )}{2 d}\) | \(109\) |
[In]
[Out]
none
Time = 0.27 (sec) , antiderivative size = 71, normalized size of antiderivative = 1.09 \[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=\frac {a \cos \left (-\frac {d e - c f}{d}\right ) \operatorname {Ci}\left (\frac {d f x + c f}{d}\right ) + a \sin \left (-\frac {d e - c f}{d}\right ) \operatorname {Si}\left (\frac {d f x + c f}{d}\right ) + a \log \left (d x + c\right )}{d} \]
[In]
[Out]
\[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=a \left (\int \frac {\cos {\left (e + f x \right )}}{c + d x}\, dx + \int \frac {1}{c + d x}\, dx\right ) \]
[In]
[Out]
Result contains complex when optimal does not.
Time = 0.33 (sec) , antiderivative size = 172, normalized size of antiderivative = 2.65 \[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=\frac {\frac {2 \, a f \log \left (c + \frac {{\left (f x + e\right )} d}{f} - \frac {d e}{f}\right )}{d} - \frac {{\left (f {\left (E_{1}\left (\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right ) + E_{1}\left (-\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right )\right )} \cos \left (-\frac {d e - c f}{d}\right ) + f {\left (i \, E_{1}\left (\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right ) - i \, E_{1}\left (-\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right )\right )} \sin \left (-\frac {d e - c f}{d}\right )\right )} a}{d}}{2 \, f} \]
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 0.30 (sec) , antiderivative size = 673, normalized size of antiderivative = 10.35 \[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=\text {Too large to display} \]
[In]
[Out]
Timed out. \[ \int \frac {a+a \cos (e+f x)}{c+d x} \, dx=\int \frac {a+a\,\cos \left (e+f\,x\right )}{c+d\,x} \,d x \]
[In]
[Out]